package com.jzo2o.customer.service;

import com.jzo2o.common.model.PageResult;
import com.jzo2o.customer.model.domain.WorkerCertificationAudit;
import com.baomidou.mybatisplus.extension.service.IService;
import com.jzo2o.customer.model.dto.request.CertificationAuditReqDTO;
import com.jzo2o.customer.model.dto.request.WorkerCertificationAuditAddReqDTO;
import com.jzo2o.customer.model.dto.request.WorkerCertificationAuditPageQueryReqDTO;
import com.jzo2o.customer.model.dto.response.RejectReasonResDTO;
import com.jzo2o.customer.model.dto.response.WorkerCertificationAuditResDTO;

/**
 * <p>
 * 服务人员认证审核表 服务类
 * </p>
 *
 * @author itcast
 * @since 2025-03-05
 */
public interface IWorkerCertificationAuditService extends IService<WorkerCertificationAudit> {

    /**
     * 应用认证信息
     *
     * @param workerCertificationAuditAddReqDTO 包含认证申请详细信息的DTO对象
     */
    void applyCertification(WorkerCertificationAuditAddReqDTO workerCertificationAuditAddReqDTO);

    /**
     * 查询当前用户最后一次的拒绝原因
     *
     * @return 包含最后一次认证被拒绝原因的DTO对象
     */
    RejectReasonResDTO queryCurrentUserLastRejectReason();

    /**
     * 分页查询认证信息
     * @param workerCertificationAuditPageQueryReqDTO 分页查询条件
     * @return
     */
    PageResult<WorkerCertificationAuditResDTO> pageQuery(WorkerCertificationAuditPageQueryReqDTO workerCertificationAuditPageQueryReqDTO);

    /**
     * 审核认证信息
     * @param id                        申请记录id
     * @param certificationAuditReqDTO  审核请求
     */
    void auditCertification(Long id, CertificationAuditReqDTO certificationAuditReqDTO);
}
